<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            
            margin: 0;
            padding: 0;
        }
        #app{
            width: 96%;
            margin: auto ;
            
        }
        header{
            background-color: blueviolet;
        }
        header h1{
            color: white;
            font-weight: 400;
            margin: 0 0 5px 15px;
        }
        header input{
            width: 95%;
            margin: 8px;
            border: none;
            height: 35px;
            background-color: aliceblue;
            border-radius: 35px;
            text-align: center;
        }
        #app .list1{
            display: flex;
            justify-content: space-between;
            text-align: center;
            margin: 15px 0;
        }
        #app .list1 span{
            width: 25%;
        }
        #app .list2{
            display: flex;
            justify-content: space-between;
            text-align: center;
        }
        #app .list2 span{
            background-color: #f5f5f5;
            margin-bottom: 10px;
            text-align: center;
            border-radius: 6px;
            padding: 5px;
        }

        #app .card .card1{
            height: 140px;
        }
        #app .card .card1 img{
            height: 100px;
            width: 100px;
            float: left;
            margin:5px;
        }

        #app .card .card1 .score{
            font-size: 12px;
            color: red;
            display: inline-block;
            margin-top: 10px;
        }
        #app .card .card1 .sell{
            font-size: 12px;
        }
        #app .card .card1 .money{
            font-size: 12px;
        }
        #app .card .card1 .time{
            font-size: 12px;
            float:right;
        }
        #app .card .card1 .appraise{
            font-size: 12px;
            background-color: rgb(187, 255, 170);
            color: green;
            margin: 5px 2px;
            display: inline-block;
        }
        #app .card .card1 .reduce{
            font-size: 12px;
            border-radius: 5px;
            border: 1px red solid;
            margin: 0 2px;
            color: red;
            padding: 1px;
        }
        footer{
            width: 100%;
            text-align: center;
            position: fixed;
            bottom: 0;
            display: flex;
            justify-content: space-between;
            border: 1px solid #f5f5f5;
            height: 40px;
        }
        footer .foot{
            width: 33%;
        }
    </style>
</head>
<body>
        <header>
            <h1>饿了么</h1>
            <input type="text" placeholder="输入商家、商品名称">
        </header>
    <div id="app">    
        <div style="height: 100px;" ></div>
        <h3>猜你喜欢</h3>
        <div class="list1">
            <span v-for="(item,index) in arr" :style="{fontWeight: nowIndex == index?700:400}" @click="handleClick(index)">{{item}}</span>
        </div>
        <div class="list2">
            <span v-for="(item,index) in arr1">{{item}}</span>
        </div>
        <div class="card">
            <div class="card1" v-for="(item,index) in information">
                <img :src="item.pic" >
                <h3>{{item.name}}</h3>
                <span class="score">星 {{item.score}}</span>
                <span class="sell">月售 {{item.sell}}</span><br>
                <span class="money">起送￥20 远距离配送￥{{item.money}}</span>
                <span class="time">{{item.minute}}分钟 {{item.km}}km </span><br>
                <!-- <span class="appraise">"{{item.appraise}}"</span> -->
                <span class="appraise" v-for="(item,index) in item.appraise">"{{item}}"</span><br>
                <span class="reduce" v-for="(item,index) in item.reduce">{{item}}</span>
            </div>
        </div>
        
    </div>
        <footer >
            <span class="foot" v-for="(item,index) in arr2" @click="handleClick(index)" :style="{color:currentIndex==index?'red':'' }">{{item}}</span>
        </footer>

</body>
</html>
<script src="./vue-2.5.21.js"></script>
<script src="./elm.js"></script>